package com.hoangkien.apdater;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.TextView;

import com.hoangkien.soundcloud.R;

public class AdapterMenuTab extends BaseAdapter {

	private Context context;
	private String[] mArrayList;
	private TextView text;

	public AdapterMenuTab(Context context, String[] mArrayList) {
		this.context = context;
		this.mArrayList = mArrayList;
	}

	@Override
	public int getCount() {
		return mArrayList.length;
	}

	@Override
	public Object getItem(int position) {
		return getItem(position);
	}

	@Override
	public long getItemId(int position) {
		return position;
	}

	@Override
	public View getView(int position, View convertView, ViewGroup parent) {
		LayoutInflater inflater2 = LayoutInflater.from(context);
		View view = inflater2.inflate(R.layout.adapter_layout_left, null);
		text = (TextView) view.findViewById(R.id.text_menu_left);
		text.setText(mArrayList[position]);
		return view;
	}

}
